//index.php
 function __autoload($class)
 {
     require_once($class . '.php');
 }
 
$test = new Test();
 echo $test;
 //hello